import Vue from "vue";
import VueRouter from "vue-router";

Vue.use(VueRouter);

const routes = [
  {
    path: "/",
    redirect: "/list",
  },
  {
    path: "/list",
    name: "list",
    component: () => import("../views/List.vue"),
  },
  {
    path: "/search",
    name: "search",
    component: () => import("../views/Search.vue"),
  },
  {
    path: "/shopcar",
    name: "shopcar",
    component: () => import("../views/Shopcar.vue"),
  },
  {
    path: "/my",
    name: "my",
    component: () => import("../views/My.vue"),
  },
  {
    path: "/detail",
    name: "detail",
    component: () => import("../views/Detail.vue"),
  },
  {
    path: "/result",
    name: "result",
    component: () => import("../views/Result.vue"),
  },
];

const router = new VueRouter({
  routes,
});

export default router;
